'use client';
import React, { useState } from 'react';

export default function DashboardLayout({ pagelist, pagelist2, children }: { pagelist: React.ReactNode; pagelist2: React.ReactNode; children: React.ReactNode }) {
    const [change, setChange] = useState(false);
    return (
        <section>
            <nav>当前模板内容</nav>
            <button onClick={() => setChange(!change)}>切换页面组件</button>
            {change ? pagelist2 : pagelist}
        </section>
    );
}
